declare namespace System {
    interface PageInfo<T> {
        page: number,
        page_size: number,
        total_pages: number,
        total_items: number,
        datas: T[]
    }
    interface UserListInfo {
        user_id: number;
        username: string;
        nickname: string;
        status: boolean;
        created_at: string;
    }
    interface UserInfo extends UserListInfo {
        password?: string;
        status: boolean;
        phone: String | null;
        email: String | null;
        sex: 0 | 1 | 2;
        dept_id: number;
        roles: number[];
        posts: number[];
    }
    interface RoleInfo {
        id: number;
        name: string;
        key: string;
        description: string;
        data_scope: number;
        status: boolean;
    }
    interface RoleResourceInfo {
        resource_id: number;
        method: string;
        allow: boolean;
    }
    interface ResourceInfo {
        id: number;
        path: string;
        description: string;
        status: boolean;
        created_at: string;
        updated_at: string;
    }
    interface DeptInfo {
        dept_id: number;
        dept_name: string;
        order_num: number;
        parent_id: number;
        status: boolean;
        created_at: string;
        description: string;
        children?: DeptInfo[]
    }

    interface LoginLogInfo {
        id: number;
        username: string;
        result: number;
        user_ip: number;
        user_agent: string;
        created_at: string;
    }
    interface OperateLogInfo {
        id: number;
        result: number;
        request_method: string;
        request_path: string;
        request_query?: string;
        request_data?: string;
        user_ip?: string;
        operator_name?: string;
        created_at: string;
    }
    interface DictInfo {
        id: number;
        dict_name: string;
        dict_type: string;
        status: boolean;
        remark: string;
        created_at: string;
    }
    interface DictDataInfo {
        id: number;
        dict_type: string;
        dict_code: string;
        dict_value: string;
        dict_sort: number;
        created_at: string;
        status: boolean;
    }
    type PostDo = {
        name: string;
        key: string;
        description?: string;
        status?: boolean;
    }
    type PostInfo = Required<PostDo> & { id: number; }
}
